import request from '@/utils/request'

// 查询活动动态列表
export function listDynamic(query) {
  return request({
    url: '/ypp/dynamic/list',
    method: 'get',
    params: query
  })
}

// 查询活动动态详细
export function getDynamic(id) {
  return request({
    url: '/ypp/dynamic/' + id,
    method: 'get'
  })
}

// 新增活动动态
export function addDynamic(data) {
  return request({
    url: '/ypp/dynamic',
    method: 'post',
    data: data
  })
}

// 修改活动动态
export function updateDynamic(data) {
  return request({
    url: '/ypp/dynamic',
    method: 'put',
    data: data
  })
}

// 删除活动动态
export function delDynamic(id) {
  return request({
    url: '/ypp/dynamic/' + id,
    method: 'delete'
  })
}

// 导出活动动态
export function exportDynamic(query) {
  return request({
    url: '/ypp/dynamic/export',
    method: 'get',
    params: query
  })
}



// 审核
export function auditDynamic(id,status) {
  return request({
    url: '/ypp/dynamic/auditDynamic',
    method: 'get',
    params: {id:id,status:status}
  })
}
